package com.ruoyi.gatewayadmin.domain;

import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

import javax.validation.constraints.NotBlank;

/**
 * 应用权限对象 gateway_app_router
 *
 * @author Darwin
 * @date 2024-10-14
 */
public class GatewayAppRouter extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** UUID */
    private String uuid;

    /** 应用ID */
    @Excel(name = "应用ID")
    @NotBlank(message = "参数名应用ID称不能为空")
    private String appId;

    /** 路由ID */
    @Excel(name = "路由ID")
    @NotBlank(message = "参数名路由ID称不能为空")
    private String routerId;

    /** 过期时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "过期时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date expiration;
    @NotBlank(message = "选中状态为空")
    private Boolean checked;

    public @NotBlank(message = "选中状态为空") Boolean getChecked() {
        return checked;
    }

    public void setChecked(@NotBlank(message = "选中状态为空") Boolean checked) {
        this.checked = checked;
    }

    public void setUuid(String uuid)
    {
        this.uuid = uuid;
    }

    public String getUuid()
    {
        return uuid;
    }
    public void setAppId(String appId)
    {
        this.appId = appId;
    }

    public String getAppId()
    {
        return appId;
    }
    public void setRouterId(String routerId)
    {
        this.routerId = routerId;
    }

    public String getRouterId()
    {
        return routerId;
    }
    public void setExpiration(Date expiration)
    {
        this.expiration = expiration;
    }

    public Date getExpiration()
    {
        return expiration;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("uuid", getUuid())
            .append("appId", getAppId())
            .append("routerId", getRouterId())
            .append("expiration", getExpiration())
            .toString();
    }
}
